// let obj = {
//     name: 'tom',
//     age: 18
// }
// // let { name: foo, age: bar} = obj
// let {name, age} = obj //key和value相等是可以简写
// console.log(name, age);
let obj = {
     name:'tom',
     age: 18,
    like:[
        'coding',
        {x:'eat'}
    ]

}

//obj.like[1].x
let {name,like:[ , {x}]} = obj
console.log(x);
